home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 2008 March
/
PCWorld_2008-03_cd.bin
/
v cisle
/
mediacoder
/
MediaCoder-0.6.1.4045.exe
/
extensions
/
Archos404.7z
/
main.js
< prev
Wrap
Text File
|
2007-12-12
|
1KB
|
51 lines
/*************************************************************************
* MediaCoder extension - Archos AV Series
* Distributed under GPL license
* Copyright (c) 2005-06 Stanley Huang <stanleyhuangyc@yahoo.com.cn
* All rights reserved.
*************************************************************************/
function SetModel(model)
{
SendCommand("stop_play");
// switch picture
window.innerWidth = 910;
window.innerHeight = 460;
devimg.src = "404.png";
lcd.style.left = 264;
lcd.style.top = 75;
lcd.style.width = 303;
lcd.style.height = 218;
ApplyParams();
}
function ApplyParams()
{
var doc = NewXML("MediaCoderPref");
if (!doc) {
alert("Error creating config XML");
return;
}
var model = document.getElementById("model").value;
var format = document.getElementById("format").value;
//AddPrefNode(doc, "overall.video.format", format);
AddPrefNode(doc, "overall.video.bitrate", document.getElementById("vb").value);
AddPrefNode(doc, "audioenc.lame.quality", document.getElementById("aq").value);
AddPrefNode(doc, "videofilter.frame.fps", document.getElementById("fps").value);
AddPrefNode(doc, "videofilter.scale.width", 320);
AddPrefNode(doc, "videofilter.scale.height", 240);
AddPrefNode(doc, "videofilter.crop.mode", document.getElementById("crop").value);
// post settings to MediaCoder
PostPrefXML(doc);
}
function Unload()
{
// stop playback
SendCommand("stop_play");
}